package com.zszq.ms.bigmodeltest.service.impl;

import com.zszq.ms.bigmodeltest.entity.AiTemplate;
import com.zszq.ms.bigmodeltest.mapper.AiTemplateMapper;
import com.zszq.ms.bigmodeltest.service.AiTemplateService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.UUID;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author ms
 * @since 2025-03-31
 */
@Service
public class AiTemplateImpl extends ServiceImpl<AiTemplateMapper, AiTemplate> implements AiTemplateService {

    @Override
    public int add(AiTemplate aiTemplate) {
        aiTemplate.setId(UUID.randomUUID().toString());
       return baseMapper.insert(aiTemplate);
    }

    @Override
    public int update(AiTemplate aiTemplate) {
        return baseMapper.updateById(aiTemplate);
    }
}
